<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreateSrDetailTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('sr_detail', function (Blueprint $table) {
            $table->increments('id');
            $table->string('name')->default('')->comment('名称');
            $table->integer('project_id')->comment('项目id');
            $table->string('method')->default('')->comment('请求类型');
            $table->integer('on')->comment('请求状态（0开启1关闭）');
            $table->string('url')->default('')->comment('接口地址');
            $table->string('description')->nullable()->comment('接口描述');
            $table->longText('result')->nullable()->comment('请求结果');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('sr_detail');
    }
}
